package day02;

import java.io.FileInputStream;
import java.io.InputStream;

import javax.xml.parsers.SAXParser;
import javax.xml.parsers.SAXParserFactory;

public class Test1 {

	public static void main(String args[]) throws Exception {
		// SAXParser,造一个解析器
		SAXParser parser = SAXParserFactory.newInstance().newSAXParser();
		System.out.println(parser);
		InputStream in = new FileInputStream("user.xml");
		// 处理器new MySaxHandler
		parser.parse(in, new MySAXHanler());
		in.close();
	}
}